package com.s2sh.service.impl;

import java.io.Serializable;
import java.util.Collection;
import java.util.List;

import com.s2sh.dao.BaseDao;
import com.s2sh.service.BaseService;

public abstract class BaseServiceImpl<T> implements BaseService<T> {
	
	public abstract BaseDao<T> getBaseDao() ;
	
	public List<T> getAllEntry() {
		return getBaseDao().getAllEntry();
	}

	public T getEntryById(Serializable id) {
		return getBaseDao().getEntryById(id);
	}

	public void saveEntry(T entity) {
		getBaseDao().saveEntry(entity) ;
	}

	public void updateEntry(T entity) {
		getBaseDao().updateEntry(entity) ;
	}

	public void deleteEntry(Serializable id) {
		getBaseDao().deleteEntry(id) ;
	}

	public Collection<T> getEntriesByIds(Serializable... ids) {
		return getBaseDao().getEntriesByIds(ids);
	}
	
	

}
